const http = require('../../utils/http');
Page({
  data: {
    msg:"hello world",
    playlists:[]
  },
  onLoad:async function(){
    var url = "top/playlist?cat=华语&limit=21";
    var data  = await http(url);
    this.setData({
      playlists:data.data.playlists
    })
  },
  handleClick(event){
    let id = event.currentTarget.dataset.id;
    wx.navigateTo({
      url: `/pages/detail/detail?id=${id}`
    })
  }
})